package com.ruoyi.workFlow.service;

import com.github.pagehelper.Page;
import com.ruoyi.workFlow.domain.ActTaskDTO;
import com.ruoyi.workFlow.domain.dto.ActWorkflowFormDataDTO;

import java.text.ParseException;
import java.util.List;
import java.util.Map;

/**
 * @ClassName ITaskService
 * @Description 流程任务服务类
 * @Author leizhang
 * Date 2021/10/28 4:34 下午
 * @Version 1.0
 **/
public interface ITaskService {
    /**
     * 个人审核任务查询
     *
     * @param requestMap
     * @return
     */
    Page<ActTaskDTO> getTaskList(Map<String, Object> requestMap);

    /**
     * 任务完成ByTaskId
     *
     * @param requestMap
     */
    void completeTaskByTaskId(Map<String, Object> requestMap);

    /**
     * 渲染表单
     *
     * @param taskID
     * @return
     */
    public List<String> formDataShow(String taskID);

    /**
     * 表单审核
     *
     * @throws ParseException
     */
    public int formDataSave(String taskID, List<ActWorkflowFormDataDTO> awfs, Integer taskType) throws ParseException;

    /**
     * @param requestParam
     * @return void
     * @Description : 任务撤销
     * @Author : leizhang
     * @Date 9:43 下午 2021/11/4
     **/
    public void delProcessInstance(Map<String, Object> requestParam);

    /**
     * @param requestParam
     * @return java.util.List<org.activiti.api.task.model.Task>
     * @Description : 获取发起者任务信息
     * @Author : leizhang
     * @Date 11:23 上午 2021/11/6
     **/
    public com.github.pagehelper.Page<ActTaskDTO> getProcessInfoByStart(Map<String, Object> requestParam);

    /**
     * @description: 临时工流程
     * @author 刘松山
     * @date 2021/12/22 14:53
     */
    public int tempsFlowSave(String taskID, List<ActWorkflowFormDataDTO> awfs, int taskType) throws ParseException;

    /**
     * @param taskID
     * @param awfs
     * @param taskType
     * @return int
     * @Description : 运营需求单审批结果保存
     * @Author : leizhang
     * @Date 7:23 PM 2021/12/27
     **/
    public int formDataSave2(String taskID, List<ActWorkflowFormDataDTO> awfs, Integer taskType) throws ParseException;

}
